home *** CD-ROM | disk | FTP | other *** search
/ EuroCD 3 / EuroCD 3.iso / Programming / Amos / AMOSList-0198 / AMOSLIST / text0171.txt < prev    next >
Encoding:
Text File  |  1998-06-24  |  1.9 KB  |  69 lines

  1. On 29-Gen-98, Jens Vang Petersen wrote: Looooooooong Samples
  2.  
  3. >Hello..
  4.  
  5. Hi!
  6.  
  7. >A request to all of you excelent sound-extension-people. Can any of you
  8. >write a sample-replayer into your extension (or even a simple AMOS-
  9. >procedure) that can handle long raw samples (+100.000 bytes) the only
  10. >way I can find to replay those bloddy things is to call an external 
  11. >player like Play16.. Gah...
  12.  
  13.  
  14. You can try this one.... it's a double buffered replayer wich use the GUI
  15. Extension asynchronous commands for play&load datas at the same time :)
  16.  
  17. '**
  18. '**      $VER: SamPLay 1.0 (31-01-98)    
  19. '**
  20. '**      Asynchronous-Double buffered sample replayer   
  21. '**
  22. '**      © Copyright 1998 Pietro Ghizzoni - Dairymen Soft
  23. '**        FreeWare      
  24. '**
  25.  
  26.  
  27. Reserve As Chip Work 10,10000
  28. Reserve As Chip Work 11,10000
  29. F$=Fsel$("**") : Open In 1,F$ : L=Lof(1) : Close 
  30.  
  31. H=Tcp F Open(1,F$)
  32. D=Tcp Get(1,Start(10),10000) : D=Tcp Get(1,Start(11),10000)
  33. Sam Raw %1111,Start(10),10000,10000 : C=20000 : BUF=10 : BUF2=11
  34.  
  35. Do 
  36.    
  37.    Repeat : Until Sam Swapped(1)
  38.    If C>L Then Goto QUIT
  39.    
  40.    Sam Swap %1111 To Start(BUF2),10000 : A=Tcp Read(1,Start(BUF),10000)
  41.    C=C+10000 : Swap BUF,BUF2
  42.    
  43. Loop 
  44.  
  45. QUIT:
  46.  
  47. Tcp Close : End 
  48.  
  49.  
  50. -- 
  51.  
  52.  
  53. Bye!
  54.  
  55.  
  56.                                      !!!
  57.                                      o o
  58.    +-----------------------------oOO-(_)-OOo----------------------------+
  59.    |                                                                    |
  60.    |  Pietro Ghizzoni - Dairymen Soft              __  /// Amiga 12OO   |
  61.    |     E-Mail:  ghizzo@agonet.it                 \\\/// 'O3O  5OMhz   |
  62.    |            Team AMIGA                          \/// 18MB - CD4x    |
  63.    |                                                                    |
  64.    | Amos Professional Team Coordinator               AMIGA RULEZ!!     |
  65.    |                                                                    |
  66.    +--------------------------------------------------------------------+
  67.  
  68.  
  69.